<?php

namespace DatMoment\VideoBundle\Entity;
 
use Doctrine\ORM\EntityRepository;

class VideoRepository extends EntityRepository{
    
    public function getNbVideos() {
        return $this->createQueryBuilder('Video')
            ->select('COUNT(Video)')
            ->getQuery()
            ->getSingleScalarResult();
    }
}

?>
